package com.vivi.feverdiagnose;

import java.util.List;

import com.vivi.feverdiagnose.db.DataSource;
import com.vivi.feverdiagnose.R;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.util.Log;
import android.view.View;
import android.widget.ListView;

public class UserDiagnose extends Activity {
	ListView list;
	private List<DataGejala>	mListGejala;
	private DataGejala			mGejala;
	int i=0;

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.diagnose_user);
		
		final DataSource myDb = new DataSource(this);
		mListGejala = myDb.SelectAllDataGejala();
		list=(ListView)findViewById(R.id.listView1);
		
		
		do{
			mGejala = mListGejala.get(i);
			Log.d("data Gejala","id = "+mGejala.getIdGjl());
			Log.d("data Gejala","nama = "+mGejala.getNamaGjl());	
			i++;
		}while(i<mListGejala.size());
		
		
	}

	public void onButtonClicker(View v) {
		Intent intent;

		switch (v.getId()) {
		case R.id.btnCekHasil:
			intent = new Intent(this, HasilDiagnose.class);
			startActivity(intent);
			break;
		}
	}
}
